{% extends "layout/base.html" %}
{% block content %}
<ul class="rightMenuTabs">
    {% include 'osoby/_menu_gora.html' %}
</ul>
	<div class="wideBlueBorderTop"></div>
	<div class="wideBlueBorderMiddle">
		<div class="wideWhiteContent">
			<div class="wyszukiwarka">
				
			</div>
			<h2>Dodawanie osób <font color="green">{{informacja}}</font></h2>
			<div class="clear"></div>
			<hr class="short" />
			<fieldset>
                            
                            {% include '_dodaj_z_palca.html' %}

                            {% include '_import_xls.html' %}
                         
			</fieldset>
                        {% if link_dialog %}
                        {% include link_dialog %}
                        {% endif %}
		</div><!-- koniec wideWhiteContent-->
	</div><!-- koniec wideBlueBorderMiddle-->
	<div class="wideBlueBorderBottom"></div>

{% endblock %}
{% block javascripts %}
{% parent %}
      <script type="text/javascript">

$(function(){
        $('#dialog').dialog({
                        autoOpen: true,
                        width: 800,
                        height: 400,
                        modal: true ,
                        buttons: {
                                "Ok": function() {
                                jQuery('#importowanie').submit();
                                },
                                "Zamknij": function() {
                                $(this).dialog("close");
                		}
                                }
                        });
            });
    jQuery(document).ready(function(){
        jQuery("#dodaj__z_palca_2").click(function(e){
            var nazwisko=$("#nazwisko").val();
            var email=$("#email").val();
            e.preventDefault();
                    jQuery.ajax({
                            type: "POST",
                            url: "dodaj_osobe_z_palca2",
                            data: 'nazwisko='+nazwisko+'&email='+email,
                            success: function(wynik){
                                alert('Dodano osobę.');
                            }
                            });
                });
                });

      </script>
{% endblock %}
